﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace HomeWork
{
    internal class FactoryContext
    {
        //确保唯一实例的私有静态变量，仅在创建时初始化
        private static readonly FactoryContext _instance = new FactoryContext();

        // 公共访问点（供外部获取唯一实例）
        public static FactoryContext Instance => _instance;

        // 私有构造函数，阻止外部实例化
        private FactoryContext()
        {
        }


    }
}
